amends ".../snippetTest.pkl"

examples {
  ["accessing for-bound variable from a lambda in a nested for"] {
    new {
      for (l1 in List("a", "b")) {
        for (l2 in List("a", "d").filter((i) -> i == l1)) {
          l1 + l2
        }
      }
    }
  }
  ["accessing for-bound variable from a lambda in a nested when"] {
    new {
      for (l1 in List("a", "b")) {
        when (!List("a", "d").filter((i) -> i == l1).isEmpty) {
          l1
        }
      }
    }
  }
  ["accessing for-bound variable from an expression inside a nested for"] {
    new {
      for (_n in List(1, 2, 3)) {
        for (x in new App { n = _n }.list) {
          x
        }
      }
    }
  }
}

local class App {
  n: Int
  list = List(n, n, n)
}
